<?php

namespace app\api\controller\v2;

use addons\third\library\Service;
use addons\third\model\Third;
use app\common\controller\Api;
use app\common\library\Auth;
use app\common\library\Pingpp;
use app\common\library\Sms;
use app\common\library\Token;
use fast\Http;
use think\Db;
use think\Validate;

/**
 * 首页接口
 */
class Banner extends Api
{
    protected $noNeedLogin = ['getImg'];
    protected $noNeedRight = '*';

    /**
     * 根据位置标签获取页面
     * @param string $remark 标识
     * @return $result
     */
    public function getImg() {
        $remark = input('remark/s', '');
        if (!$remark) {
            $this->error('参数传递错误');
        }
        $Adszone = new \addons\adszone\library\Adszone();
        $result = $Adszone->getAdsByMark($remark); //按照标记调用广告位

        $this->success('广告位', $result);
   }
}
